package com.manlitech.cloudboot.baseboot.prox;

import org.springframework.cglib.proxy.MethodInterceptor;
import org.springframework.cglib.proxy.MethodProxy;

import java.lang.reflect.Method;

/**
 * @author shensg
 */
public class CglibProx implements MethodInterceptor {
    @Override
    public Object intercept(Object o, Method method, Object[] objects, MethodProxy methodProxy) throws Throwable {
        System.out.println("cglib在什么之前");
        Object o1 = methodProxy.invokeSuper(o, objects);
        System.out.println("cglib在什么之后");
        return o1;
    }
}
